﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MMITCore
{
    [Serializable]
    public class LocalTransaction
    {
        public long Id
        {
            get;
            set;
        }

      

        public int TransactionTypeId
        {
            get;
            set;
        }

        public string TransactionCode
        {
            get;
            set;
        }

        public DateTime? LastUpdate
        {
            get;
            set;
        }

        public DateTime? TimeInitiated
        {
            get;
            set;
        }

        public int? AuthorisationId
        {
            get;
            set;
        }

        public DateTime? TimeProcessed
        {
            get;
            set;
        }

        public DateTime? TimeFinalised
        {
            get;
            set;
        }

        public decimal? Amount
        {
            get;
            set;
        }

        public int Status
        {
            get;
            set;
        }

        public int SenderId
        {
            get;
            set;
        }

        public int RecipientId
        {
            get;
            set;
        }
        public long? ParentId
        {
            get;
            set;
        }


      

        public string coreStatus
        {
            get
            {
                return Enum.GetName(typeof(TransactionStatuses), this.Status);
            }
        }

        public enum TransactionStatuses
        {

            Initiated = 1,
            Pending = 2,
            Denied = 3,
            Cancelled = 4,
            Completed = 5
        }

      
    }
}
